import request from '@/utils/request'

export const ArticleListAPI = data => {
  return request.get('/admin/interview/query', {
    params: data
  })
}

export const createArticleAPI = data => {
  return request.post('/admin/interview/create', data)
}

// 删除方法
export const removeArticleAPI = id => {
  // return request.delete('/admin/interview/remove', {
  //   data: { id }
  // })
  return request({
    method: 'DELETE',
    url: '/admin/interview/remove',
    data: { id }
  })
}

// 单个面经详情
export const articleAPI = id => {
  return request({
    url: '/admin/interview/show',
    params: { id }
  })
}

export const updateArticleAPI = data => {
  return request.put('/admin/interview/update', data)
}
